package Util;

import java.awt.Image;

import javax.swing.ImageIcon;

public class FilterNumber {
	
	private Image icon0;
	private Image icon1;
	private Image icon2;
	private Image icon3;
	private Image icon4;
	private Image icon5;
	private Image icon6;
	private Image icon7;
	private Image icon8;
	private Image icon9;
	private Image icon0m;
	private Image icon1m;
	private Image icon2m;
	private Image icon3m;
	private Image icon4m;
	private Image icon5m;
	private Image icon6m;
	private Image icon7m;
	private Image icon8m;
	private Image icon9m;
	
	public FilterNumber() {
		icon0 = new ImageIcon(getClass().getResource("/Sprites/0.png")).getImage();
		icon1 = new ImageIcon(getClass().getResource("/Sprites/1.png")).getImage();
		icon2 = new ImageIcon(getClass().getResource("/Sprites/2.png")).getImage();
		icon3 = new ImageIcon(getClass().getResource("/Sprites/3.png")).getImage();
		icon4 = new ImageIcon(getClass().getResource("/Sprites/4.png")).getImage();
		icon5 = new ImageIcon(getClass().getResource("/Sprites/5.png")).getImage();
		icon6 = new ImageIcon(getClass().getResource("/Sprites/6.png")).getImage();
		icon7 = new ImageIcon(getClass().getResource("/Sprites/7.png")).getImage();
		icon8 = new ImageIcon(getClass().getResource("/Sprites/8.png")).getImage();
		icon9 = new ImageIcon(getClass().getResource("/Sprites/9.png")).getImage();
		icon0m = new ImageIcon(getClass().getResource("/Sprites/0m.png")).getImage();
		icon1m = new ImageIcon(getClass().getResource("/Sprites/1m.png")).getImage();
		icon2m = new ImageIcon(getClass().getResource("/Sprites/2m.png")).getImage();
		icon3m = new ImageIcon(getClass().getResource("/Sprites/3m.png")).getImage();
		icon4m = new ImageIcon(getClass().getResource("/Sprites/4m.png")).getImage();
		icon5m = new ImageIcon(getClass().getResource("/Sprites/5m.png")).getImage();
		icon6m = new ImageIcon(getClass().getResource("/Sprites/6m.png")).getImage();
		icon7m = new ImageIcon(getClass().getResource("/Sprites/7m.png")).getImage();
		icon8m = new ImageIcon(getClass().getResource("/Sprites/8m.png")).getImage();
		icon9m = new ImageIcon(getClass().getResource("/Sprites/9m.png")).getImage();
	}
	
public Image setImage(int x, int tam) {
		
		switch(tam) {
			case 1:
				switch(x) {
				case 0:
					return icon0m;
				case 1:
					return icon1m;
				case 2:
					return icon2m;
				case 3:
					return icon3m;
				case 4:
					return icon4m;
				case 5:
					return icon5m;
				case 6:
					return icon6m;
				case 7:
					return icon7m;
				case 8:
					return icon8m;
				case 9:
					return icon9m;
				default:
					return icon0m;	
			}
				
			case 2:
				switch(x) {
					case 0:
						return icon0;
					case 1:
						return icon1;
					case 2:
						return icon2;
					case 3:
						return icon3;
					case 4:
						return icon4;
					case 5:
						return icon5;
					case 6:
						return icon6;
					case 7:
						return icon7;
					case 8:
						return icon8;
					case 9:
						return icon9;
					default:
						return icon0;	
				}
			default:
				return null;
		}

		
	}

}
